<template>
  <div class="main">
    <MyHeader bgc="skyblue" title="购物车案例"></MyHeader>
    <div class="main">
      <MyGoods v-for="obj in list" :key="obj.id" :gObj="obj"></MyGoods>
    </div>
    <MyFooter :arr="list"></MyFooter>
  </div>
</template>

<script>
import MyHeader from "./components/MyHeader";
import MyGoods from "./components/MyGoods";
import MyFooter from "./components/MyFooter";
import axios from "axios";
// 获取-购物车列表接口  GET  https://applet-base-api-t.itheima.net/api/cart

export default {
  data() {
    return {
      list: [], // 商品所有数据
    };
  },
  components: {
    MyHeader,
    MyGoods,
    MyFooter,
  },
};
</script>

<style scoped>
.main {
  padding-top: 45px;
  padding-bottom: 50px;
}
</style>
